#ifndef PARTICLEENGINE_H
#define PARTICLEENGINE_H

#include <string>
#include <vector>

#include "textureManager.h"
#include "entityEngine.h"
#include "mathFunctions.h"
class particle{
protected:
	float xVel, yVel, zVel;
	int life;
	std::string blendType; //pointer to function instead? THIS SHOULD BE IN ENTITY ALONG WITH THE TEXTURE DRRrr WHAT ARE YOU RETARDED?

	entity* e;
    //Visuals
    float cR, cG, cB; //Color Red/Blue/Green represented as [0,255]
    float alpha; //Alpha value represented as [0,255]
    float width, height;
    std::string textureID;
    float rotation;

public:
	particle(float x, float y, float z, int life, 
		std::string textureID, float width, float height, 
		float cR, float cG, float cB, float alpha,
		float cRinc, float cGinc, float cBinc, float aplhaInc,
		float widthInc, float heightInc);
	particle(float x=0, float y=0, float z=0, int life=80);
	~particle();
	void update();
	void draw();

	void lifeHandle();
	int getLife();
};

class emitter{
private:
	std::vector<particle*> particleList;
public:
	emitter();
	~emitter();

	void update();
};

#endif